<?
	get_header();
?>
	<div id="main">
			<div class="cont">
				<div id="breadcrumbs">
						<? get_breadcrumbs(); ?>
				</div>
				<div id="bookmarks">
					<? get_bmarks(); ?>
				</div>

				<div id="content-top">
					<div id="content-bottom">
                        <div id="content-center">

                           <div id="content">

                            	<div id="blog-title" class="alpha">
                            	  	<div id="blog-back">
                            	  		<a href="#" onClick="history.back(); return false;">> Back</a>
                            	  	</div>
                            	</div>
                               <div id="content-text">

<?php global $wp_query; $total_pages = $wp_query->max_num_pages; if ( $total_pages > 1 ) { ?>
    <div id="nav-above" class="navigation">
     <div class="nav-previous"><?php next_posts_link(__( '<span class="meta-nav">&laquo;</span> Older posts', 'Inweave' )) ?></div>
     <div class="nav-next"><?php previous_posts_link(__( 'Newer posts <span class="meta-nav">&raquo;</span>', 'Inweave' )) ?></div>
    </div>
<?php } ?>
                      <?

						 blog_get_content();

                      ?>



                      <?

	if (!empty($_SERVER['SCRIPT_FILENAME']) && 'comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
		die ('Please do not load this page directly. Thanks!');

	if ( post_password_required() ) { ?>
		<p class="nocomments">This post is password protected. Enter the password to view comments.</p>
	<?php
		return;
	}
?>
<a name="comments"></a>
<!-- You can start editing here. -->
<?

    $post_id = get_the_ID();
  	$str = "select * from `wp_comments` where `comment_post_ID` = ".$post_id." and `comment_approved` = 1";
  	//echo $str;
    $query = mysql_query($str);
  	$cc=1;
    while($row = mysql_fetch_object($query))
    {

                      ?>
                        <!-- COMMENT -->
                            	<div class="blog-post-top">
                                    	<div class="blog-title-top">
                            				<div class="blog-title-bot">
                            					<div class="blog-title-cont">
                            					    <div class="blog-title">
                            							Responce # <? echo $row->comment_post_ID; ?>
                            						</div>
                            					    <div class="blog-title-posted">
                            							Posted by: <? echo $row->comment_author; ?> - <? echo $row->comment_date; ?>
                            						</div>
                            					</div>
                            				</div>
                            			</div>
                            	    <div class="faq-block-bottom">
                            	        <div class="blog-post-center">
                                            <div class="blog-post">
                                             <? echo $row->comment_content; ?>
                                            </div>
                                        </div>
                            	    </div>
                            	</div>
                        <!-- // -->
<?
}

?>


                            	<div class="comment-top">
                                    	<div class="comment-title-top">
                            				<div class="comment-title-bot">
                            					<div class="comment-title-cont">
                            					    <div class="blog-title">
                            							Leave a Reply
                            						</div>
                            					    <div class="blog-title-posted">
                            							Note: All fields are required
                            						</div>
                            					</div>
                            				</div>
                            			</div>
                            	    <div class="comment-bottom">
                            	        <div class="comment-center">
                                            <div class="blog-post">

                                               <form action="/wp-comments-post.php" method="post" id="commentform">
                                                  <div id="comment-form">
														<div id="comment-name">
		                                                	<div id="comment-name-intblock">
		                                                           <input type="text" name="name" class="comment-inpt" value="">
		                                           	        </div>
	                                                    </div>
	                                                	<div id="comment-email">
		                                                	<div id="comment-email-intblock">
		                                                			<input type="text" name="email" class="comment-inpt" value="">
		                                                	</div>
	                                                    </div>
	                                                 	<div id="comment-message">
		                                                	<div id="comment-message-intblock">
		                                                			<textarea name="comment" id="comment-messbox">
		                                                			</textarea>
		                                                	</div>
	                                                    </div>
                                                        <input type="hidden" name="url" id="url" value="" size="22" tabindex="3" />
                                                        <input type='hidden' name='comment_post_ID' value='<? the_ID(); ?>' id='comment_post_ID' />
														<input type='hidden' name='comment_parent' id='comment_parent' value='0' />

	                                                    <input type="submit" id="comment-submit" name="submit" value="">

	                                                </div>
                                                 </form>
                                            </div>
                                        </div>
                            	    </div>
                            	</div>
                        <!-- // -->

                           </div>

		                </div>
		                </div>
                    </div>
				</div>
					<div id="sidebarcont-top">
					    <div id="sidebarcont-bottom">
							<div id="sidebar">

                                <? get_block_blogcat();?>

                                <? get_block_blogarchive();?>

                                <? get_blog_blogrecent();?>

							</div>
						</div>
                    </div>
			</div>

	</div>
<?
	get_footer();
?>